<?php
namespace app\api\controller;
use app\common\controller\Frontend;
use app\common\model\Article as ArticleModel;
use app\common\model\ArticleCategory;
class Article extends Api{

    public function page($id=null){
        $info = ArticleCategory::get($id)->toArray();
        
        $this->assign('info',$info);
        return $this->view->fetch();
        
    }
    public function category(){
       $list =  ArticleCategory::where('status',1)->select();

       $this->assign('list',$list);
        return $this->view->fetch();
    }
}